<template>

</template>

<el-pagination

    :total="totalPage"  //修  改
>
<script>
export default {
    name: "ConsumerPage.vue"
}
function deleteAll(){
    var ids = '';
    for (let item of multipleSelection.value){
        ids+=ids.substring(0,ids.length-1);
        deleteMultiRow(ids);
    }
    async function deleteMultiRow(ids){
        const result = (await HttpManager.deleteUsers(ids)) as ResponseBody;
        (proxy as any).$message({
            message: result.message,
            type: result.type,
        });
        if(result) getData();
        delVisible.value = false;
    }
    const totalPage = ref(1);//总页数  新增参数

    // 获取用户信息
    async function getData() {
        tableData.value = [];
        tempDate.value = [];
        const result = (await HttpManager.getAllUser(currentPage.value,pageSize.value)) as ResponseBody;
        //修改以下代码
        tableData.value = result.data.records;
        tempDate.value = result.data.records;
        totalPage.value = result.data.total;
    }
// 获取当前页
    function handleCurrentChange(val) {
        currentPage.value = val;
        getData();
    }
}
</script>

<style scoped>

</style>